package cn.laixueit.resource.feign.controller;

import cn.laixueit.resource.feign.client.DataDictDetailFeign;
import cn.laixueit.resource.feign.result.R;
import cn.laixueit.source.api.DataDictDetailInterface;
import cn.laixueit.source.po.TbDataDictDetail;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @author duxiang
 * @date 2024/3/8 15:22
 */
@RestController
@Slf4j
public class DataDictDetailController implements DataDictDetailInterface {
    @Resource
    private DataDictDetailFeign dataDictDetailFeign;

    @Override
    public R save(TbDataDictDetail dataDictDetail) {
        return R.data(dataDictDetailFeign.save(dataDictDetail)) ;
    }

    @Override
    public R update(TbDataDictDetail dataDictDetail) {
        return R.data(dataDictDetailFeign.update(dataDictDetail));
    }

    @Override
    public R remove(TbDataDictDetail dataDictDetail) {
        return R.data(dataDictDetailFeign.remove(dataDictDetail));
    }

    @Override
    public R get(TbDataDictDetail dataDictDetail) {
        return R.data(dataDictDetailFeign.get(dataDictDetail));
    }

    @Override
    public R list(TbDataDictDetail dataDictDetail) {
        return R.data(dataDictDetailFeign.list(dataDictDetail));
    }

    @Override
    public R page(Integer page, Integer size, TbDataDictDetail dataDictDetail) {
        return R.data(dataDictDetailFeign.page(page, size, dataDictDetail));
    }
}
